/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package GUI;

import java.awt.Frame;

/**
 * Beinhaltet Startbildschirm und die jeweiligen Events
 * @author Sebastian Weißenbacher
 */
public class Startbildschirm extends javax.swing.JFrame {

    /**
     * Creates new form Startbildschirm
     */
    public Startbildschirm() {
        initComponents();
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        cmdMedienverwaltung = new javax.swing.JButton();
        cmdAusRueck = new javax.swing.JButton();
        cmdKundenverwaltung = new javax.swing.JButton();
        jLabel2 = new javax.swing.JLabel();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("ASDT-Movie 1.0");

        cmdMedienverwaltung.setText("Medienverwaltung");
        cmdMedienverwaltung.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                cmdMedienverwaltungMouseClicked(evt);
            }
        });

        cmdAusRueck.setText("Ausleihen/Rückgabe");
        cmdAusRueck.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                cmdAusRueckMouseClicked(evt);
            }
        });

        cmdKundenverwaltung.setText("Kundenverwaltung");
        cmdKundenverwaltung.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                cmdKundenverwaltungMouseClicked(evt);
            }
        });

        jLabel2.setFont(new java.awt.Font("Tahoma", 1, 24)); // NOI18N
        jLabel2.setForeground(new java.awt.Color(0, 0, 255));
        jLabel2.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel2.setText("ASTD-Movie");

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGap(70, 70, 70)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel2, javax.swing.GroupLayout.DEFAULT_SIZE, 169, Short.MAX_VALUE)
                    .addComponent(cmdKundenverwaltung, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(cmdMedienverwaltung, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(cmdAusRueck, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addGap(70, 70, 70))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGap(40, 40, 40)
                .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 40, Short.MAX_VALUE)
                .addComponent(cmdKundenverwaltung, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(30, 30, 30)
                .addComponent(cmdMedienverwaltung, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(30, 30, 30)
                .addComponent(cmdAusRueck, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(40, 40, 40))
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents
/**
 * Öffnet Medienverwaltungsfenster
 * @param evt = MouseClicked
 */
    private void cmdMedienverwaltungMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_cmdMedienverwaltungMouseClicked
           
        MedienverGUI mdv = new MedienverGUI();
        mdv.setVisible(true);
    }//GEN-LAST:event_cmdMedienverwaltungMouseClicked
/**
 * Öffnet Ausleihe-/Rückgabefenster
 * @param evt = MouseClicked
 */
    private void cmdAusRueckMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_cmdAusRueckMouseClicked
        
        Aus_RueckGUI ausrueck = new Aus_RueckGUI();
        ausrueck.setVisible(true); 
    }//GEN-LAST:event_cmdAusRueckMouseClicked
/**
 * Öffnet Kundenverwaltungsfenster
 * @param evt = MouseClicked
 */
    private void cmdKundenverwaltungMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_cmdKundenverwaltungMouseClicked
        
        Kundenverwaltung kunden = new Kundenverwaltung();
        kunden.setVisible(true);
    }//GEN-LAST:event_cmdKundenverwaltungMouseClicked

    /**
     * @param args the command line arguments
     */
   public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(Startbildschirm.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(Startbildschirm.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(Startbildschirm.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(Startbildschirm.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new Startbildschirm().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton cmdAusRueck;
    private javax.swing.JButton cmdKundenverwaltung;
    private javax.swing.JButton cmdMedienverwaltung;
    private javax.swing.JLabel jLabel2;
    // End of variables declaration//GEN-END:variables
}
